// Josh made this

#ifndef LOG_H
#define LOG_H

#include "object.h"
#include "SFML\Graphics.hpp"
#include "Factory.h"
#include "TextureMap.h"


class LogObject : public Object
{
protected:

	LogObject() // Log constructer
	{
		logSprite = sf::Sprite(*TT::TextureLibrary[arrayText[2]]); // Loading the texture from slot 2 (third in the array) for out new sprite.
		logSprite.setPosition(1110, 200); // Setting the log sprites spawning position.
	}

	void Render();

	void Update();

public:
	static LogObject * Create(SFML_TEXTURE_HPP)
	{
		LogObject *myObject = new LogObject(); // Creating a new pointer to a new log object.
		Factory::AddObject(myObject); // Adding the new log to our object factory.
		return myObject;
	}

	static sf::Texture* logTex; // This is declaring the new texture for our log.
	sf::Sprite logSprite; // This is delcaring the new sprite for our log.
};



#endif // LOG_H